{"ast":null,"code":"import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport { useRef, useState } from 'react';\nimport Align from 'rc-align';\nimport useLayoutEffect from \"rc-util/es/hooks/useLayoutEffect\";\nimport CSSMotion from 'rc-motion';\nimport classNames from 'classnames';\nimport useVisibleStatus from \"./useVisibleStatus\";\nimport { getMotion } from \"../utils/legacyUtil\";\nimport useStretchStyle from \"./useStretchStyle\";\nvar PopupInner = /*#__PURE__*/React.forwardRef(function (props, ref) {\n  var visible = props.visible,\n    prefixCls = props.prefixCls,\n    className = props.className,\n    style = props.style,\n    children = props.children,\n    zIndex = props.zIndex,\n    stretch = props.stretch,\n    destroyPopupOnHide = props.destroyPopupOnHide,\n    forceRender = props.forceRender,\n    align = props.align,\n    point = props.point,\n    getRootDomNode = props.getRootDomNode,\n    getClassNameFromAlign = props.getClassNameFromAlign,\n    onAlign = props.onAlign,\n    onMouseEnter = props.onMouseEnter,\n    onMouseLeave = props.onMouseLeave,\n    onMouseDown = props.onMouseDown,\n    onTouchStart = props.onTouchStart,\n    onClick = props.onClick;\n  var alignRef = useRef();\n  var elementRef = useRef();\n  var _useState = useState(),\n    _useState2 = _slicedToArray(_useState, 2),\n    alignedClassName = _useState2[0],\n    setAlignedClassName = _useState2[1]; // ======================= Measure ========================\n\n  var _useStretchStyle = useStretchStyle(stretch),\n    _useStretchStyle2 = _slicedToArray(_useStretchStyle, 2),\n    stretchStyle = _useStretchStyle2[0],\n    measureStretchStyle = _useStretchStyle2[1];\n  function doMeasure() {\n    if (stretch) {\n      measureStretchStyle(getRootDomNode());\n    }\n  } // ======================== Status ========================\n\n  var _useVisibleStatus = useVisibleStatus(visible, doMeasure),\n    _useVisibleStatus2 = _slicedToArray(_useVisibleStatus, 2),\n    status = _useVisibleStatus2[0],\n    goNextStatus = _useVisibleStatus2[1]; // ======================== Aligns ========================\n\n  /**\n   * `alignedClassName` may modify `source` size,\n   * which means one time align may not move to the correct position at once.\n   *\n   * We will reset `alignTimes` for each status switch to `alignPre`\n   * and let `rc-align` to align for multiple times to ensure get final stable place.\n   * Currently we mark `alignTimes < 2` repeat align, it will increase if user report for align issue.\n   * \n   * Update:\n   * In React 18. `rc-align` effect of align may faster than ref called trigger `forceAlign`.\n   * We adjust this to `alignTimes < 2`.\n   * We need refactor `rc-align` to support mark of `forceAlign` call if this still happen.\n   */\n\n  var _useState3 = useState(0),\n    _useState4 = _slicedToArray(_useState3, 2),\n    alignTimes = _useState4[0],\n    setAlignTimes = _useState4[1];\n  var prepareResolveRef = useRef();\n  useLayoutEffect(function () {\n    if (status === 'alignPre') {\n      setAlignTimes(0);\n    }\n  }, [status]); // `target` on `rc-align` can accept as a function to get the bind element or a point.\n  // ref: https://www.npmjs.com/package/rc-align\n\n  function getAlignTarget() {\n    if (point) {\n      return point;\n    }\n    return getRootDomNode;\n  }\n  function forceAlign() {\n    var _alignRef$current;\n    (_alignRef$current = alignRef.current) === null || _alignRef$current === void 0 ? void 0 : _alignRef$current.forceAlign();\n  }\n  function onInternalAlign(popupDomNode, matchAlign) {\n    var nextAlignedClassName = getClassNameFromAlign(matchAlign);\n    if (alignedClassName !== nextAlignedClassName) {\n      setAlignedClassName(nextAlignedClassName);\n    } // We will retry multi times to make sure that the element has been align in the right position.\n\n    setAlignTimes(function (val) {\n      return val + 1;\n    });\n    if (status === 'align') {\n      onAlign === null || onAlign === void 0 ? void 0 : onAlign(popupDomNode, matchAlign);\n    }\n  } // Delay to go to next status\n\n  useLayoutEffect(function () {\n    if (status === 'align') {\n      // Repeat until not more align needed\n      if (alignTimes < 3) {\n        forceAlign();\n      } else {\n        goNextStatus(function () {\n          var _prepareResolveRef$cu;\n          (_prepareResolveRef$cu = prepareResolveRef.current) === null || _prepareResolveRef$cu === void 0 ? void 0 : _prepareResolveRef$cu.call(prepareResolveRef);\n        });\n      }\n    }\n  }, [alignTimes]); // ======================== Motion ========================\n\n  var motion = _objectSpread({}, getMotion(props));\n  ['onAppearEnd', 'onEnterEnd', 'onLeaveEnd'].forEach(function (eventName) {\n    var originHandler = motion[eventName];\n    motion[eventName] = function (element, event) {\n      goNextStatus();\n      return originHandler === null || originHandler === void 0 ? void 0 : originHandler(element, event);\n    };\n  });\n  function onShowPrepare() {\n    return new Promise(function (resolve) {\n      prepareResolveRef.current = resolve;\n    });\n  } // Go to stable directly when motion not provided\n\n  React.useEffect(function () {\n    if (!motion.motionName && status === 'motion') {\n      goNextStatus();\n    }\n  }, [motion.motionName, status]); // ========================= Refs =========================\n\n  React.useImperativeHandle(ref, function () {\n    return {\n      forceAlign: forceAlign,\n      getElement: function getElement() {\n        return elementRef.current;\n      }\n    };\n  }); // ======================== Render ========================\n\n  var mergedStyle = _objectSpread(_objectSpread({}, stretchStyle), {}, {\n    zIndex: zIndex,\n    opacity: status === 'motion' || status === 'stable' || !visible ? undefined : 0,\n    // Cannot interact with disappearing elements\n    // https://github.com/ant-design/ant-design/issues/35051#issuecomment-1101340714\n    pointerEvents: !visible && status !== 'stable' ? 'none' : undefined\n  }, style); // Align status\n\n  var alignDisabled = true;\n  if (align !== null && align !== void 0 && align.points && (status === 'align' || status === 'stable')) {\n    alignDisabled = false;\n  }\n  var childNode = children; // Wrapper when multiple children\n\n  if (React.Children.count(children) > 1) {\n    childNode = /*#__PURE__*/React.createElement(\"div\", {\n      className: \"\".concat(prefixCls, \"-content\")\n    }, children);\n  }\n  return /*#__PURE__*/React.createElement(CSSMotion, _extends({\n    visible: visible,\n    ref: elementRef,\n    leavedClassName: \"\".concat(prefixCls, \"-hidden\")\n  }, motion, {\n    onAppearPrepare: onShowPrepare,\n    onEnterPrepare: onShowPrepare,\n    removeOnLeave: destroyPopupOnHide,\n    forceRender: forceRender\n  }), function (_ref, motionRef) {\n    var motionClassName = _ref.className,\n      motionStyle = _ref.style;\n    var mergedClassName = classNames(prefixCls, className, alignedClassName, motionClassName);\n    return /*#__PURE__*/React.createElement(Align, {\n      target: getAlignTarget(),\n      key: \"popup\",\n      ref: alignRef,\n      monitorWindowResize: true,\n      disabled: alignDisabled,\n      align: align,\n      onAlign: onInternalAlign\n    }, /*#__PURE__*/React.createElement(\"div\", {\n      ref: motionRef,\n      className: mergedClassName,\n      onMouseEnter: onMouseEnter,\n      onMouseLeave: onMouseLeave,\n      onMouseDownCapture: onMouseDown,\n      onTouchStartCapture: onTouchStart,\n      onClick: onClick,\n      style: _objectSpread(_objectSpread({}, motionStyle), mergedStyle)\n    }, childNode));\n  });\n});\nPopupInner.displayName = 'PopupInner';\nexport default PopupInner;","map":{"version":3,"names":["_extends","_objectSpread","_slicedToArray","React","useRef","useState","Align","useLayoutEffect","CSSMotion","classNames","useVisibleStatus","getMotion","useStretchStyle","PopupInner","forwardRef","props","ref","visible","prefixCls","className","style","children","zIndex","stretch","destroyPopupOnHide","forceRender","align","point","getRootDomNode","getClassNameFromAlign","onAlign","onMouseEnter","onMouseLeave","onMouseDown","onTouchStart","onClick","alignRef","elementRef","_useState","_useState2","alignedClassName","setAlignedClassName","_useStretchStyle","_useStretchStyle2","stretchStyle","measureStretchStyle","doMeasure","_useVisibleStatus","_useVisibleStatus2","status","goNextStatus","_useState3","_useState4","alignTimes","setAlignTimes","prepareResolveRef","getAlignTarget","forceAlign","_alignRef$current","current","onInternalAlign","popupDomNode","matchAlign","nextAlignedClassName","val","_prepareResolveRef$cu","call","motion","forEach","eventName","originHandler","element","event","onShowPrepare","Promise","resolve","useEffect","motionName","useImperativeHandle","getElement","mergedStyle","opacity","undefined","pointerEvents","alignDisabled","points","childNode","Children","count","createElement","concat","leavedClassName","onAppearPrepare","onEnterPrepare","removeOnLeave","_ref","motionRef","motionClassName","motionStyle","mergedClassName","target","key","monitorWindowResize","disabled","onMouseDownCapture","onTouchStartCapture","displayName"],"sources":["/Users/poppie/Desktop/development/messenger/app/frontend/node_modules/rc-trigger/es/Popup/PopupInner.js"],"sourcesContent":["import _extends from \"@babel/runtime/helpers/esm/extends\";\nimport _objectSpread from \"@babel/runtime/helpers/esm/objectSpread2\";\nimport _slicedToArray from \"@babel/runtime/helpers/esm/slicedToArray\";\nimport * as React from 'react';\nimport { useRef, useState } from 'react';\nimport Align from 'rc-align';\nimport useLayoutEffect from \"rc-util/es/hooks/useLayoutEffect\";\nimport CSSMotion from 'rc-motion';\nimport classNames from 'classnames';\nimport useVisibleStatus from \"./useVisibleStatus\";\nimport { getMotion } from \"../utils/legacyUtil\";\nimport useStretchStyle from \"./useStretchStyle\";\nvar PopupInner = /*#__PURE__*/React.forwardRef(function (props, ref) {\n  var visible = props.visible,\n      prefixCls = props.prefixCls,\n      className = props.className,\n      style = props.style,\n      children = props.children,\n      zIndex = props.zIndex,\n      stretch = props.stretch,\n      destroyPopupOnHide = props.destroyPopupOnHide,\n      forceRender = props.forceRender,\n      align = props.align,\n      point = props.point,\n      getRootDomNode = props.getRootDomNode,\n      getClassNameFromAlign = props.getClassNameFromAlign,\n      onAlign = props.onAlign,\n      onMouseEnter = props.onMouseEnter,\n      onMouseLeave = props.onMouseLeave,\n      onMouseDown = props.onMouseDown,\n      onTouchStart = props.onTouchStart,\n      onClick = props.onClick;\n  var alignRef = useRef();\n  var elementRef = useRef();\n\n  var _useState = useState(),\n      _useState2 = _slicedToArray(_useState, 2),\n      alignedClassName = _useState2[0],\n      setAlignedClassName = _useState2[1]; // ======================= Measure ========================\n\n\n  var _useStretchStyle = useStretchStyle(stretch),\n      _useStretchStyle2 = _slicedToArray(_useStretchStyle, 2),\n      stretchStyle = _useStretchStyle2[0],\n      measureStretchStyle = _useStretchStyle2[1];\n\n  function doMeasure() {\n    if (stretch) {\n      measureStretchStyle(getRootDomNode());\n    }\n  } // ======================== Status ========================\n\n\n  var _useVisibleStatus = useVisibleStatus(visible, doMeasure),\n      _useVisibleStatus2 = _slicedToArray(_useVisibleStatus, 2),\n      status = _useVisibleStatus2[0],\n      goNextStatus = _useVisibleStatus2[1]; // ======================== Aligns ========================\n\n  /**\n   * `alignedClassName` may modify `source` size,\n   * which means one time align may not move to the correct position at once.\n   *\n   * We will reset `alignTimes` for each status switch to `alignPre`\n   * and let `rc-align` to align for multiple times to ensure get final stable place.\n   * Currently we mark `alignTimes < 2` repeat align, it will increase if user report for align issue.\n   * \n   * Update:\n   * In React 18. `rc-align` effect of align may faster than ref called trigger `forceAlign`.\n   * We adjust this to `alignTimes < 2`.\n   * We need refactor `rc-align` to support mark of `forceAlign` call if this still happen.\n   */\n\n\n  var _useState3 = useState(0),\n      _useState4 = _slicedToArray(_useState3, 2),\n      alignTimes = _useState4[0],\n      setAlignTimes = _useState4[1];\n\n  var prepareResolveRef = useRef();\n  useLayoutEffect(function () {\n    if (status === 'alignPre') {\n      setAlignTimes(0);\n    }\n  }, [status]); // `target` on `rc-align` can accept as a function to get the bind element or a point.\n  // ref: https://www.npmjs.com/package/rc-align\n\n  function getAlignTarget() {\n    if (point) {\n      return point;\n    }\n\n    return getRootDomNode;\n  }\n\n  function forceAlign() {\n    var _alignRef$current;\n\n    (_alignRef$current = alignRef.current) === null || _alignRef$current === void 0 ? void 0 : _alignRef$current.forceAlign();\n  }\n\n  function onInternalAlign(popupDomNode, matchAlign) {\n    var nextAlignedClassName = getClassNameFromAlign(matchAlign);\n\n    if (alignedClassName !== nextAlignedClassName) {\n      setAlignedClassName(nextAlignedClassName);\n    } // We will retry multi times to make sure that the element has been align in the right position.\n\n\n    setAlignTimes(function (val) {\n      return val + 1;\n    });\n\n    if (status === 'align') {\n      onAlign === null || onAlign === void 0 ? void 0 : onAlign(popupDomNode, matchAlign);\n    }\n  } // Delay to go to next status\n\n\n  useLayoutEffect(function () {\n    if (status === 'align') {\n      // Repeat until not more align needed\n      if (alignTimes < 3) {\n        forceAlign();\n      } else {\n        goNextStatus(function () {\n          var _prepareResolveRef$cu;\n\n          (_prepareResolveRef$cu = prepareResolveRef.current) === null || _prepareResolveRef$cu === void 0 ? void 0 : _prepareResolveRef$cu.call(prepareResolveRef);\n        });\n      }\n    }\n  }, [alignTimes]); // ======================== Motion ========================\n\n  var motion = _objectSpread({}, getMotion(props));\n\n  ['onAppearEnd', 'onEnterEnd', 'onLeaveEnd'].forEach(function (eventName) {\n    var originHandler = motion[eventName];\n\n    motion[eventName] = function (element, event) {\n      goNextStatus();\n      return originHandler === null || originHandler === void 0 ? void 0 : originHandler(element, event);\n    };\n  });\n\n  function onShowPrepare() {\n    return new Promise(function (resolve) {\n      prepareResolveRef.current = resolve;\n    });\n  } // Go to stable directly when motion not provided\n\n\n  React.useEffect(function () {\n    if (!motion.motionName && status === 'motion') {\n      goNextStatus();\n    }\n  }, [motion.motionName, status]); // ========================= Refs =========================\n\n  React.useImperativeHandle(ref, function () {\n    return {\n      forceAlign: forceAlign,\n      getElement: function getElement() {\n        return elementRef.current;\n      }\n    };\n  }); // ======================== Render ========================\n\n  var mergedStyle = _objectSpread(_objectSpread({}, stretchStyle), {}, {\n    zIndex: zIndex,\n    opacity: status === 'motion' || status === 'stable' || !visible ? undefined : 0,\n    // Cannot interact with disappearing elements\n    // https://github.com/ant-design/ant-design/issues/35051#issuecomment-1101340714\n    pointerEvents: !visible && status !== 'stable' ? 'none' : undefined\n  }, style); // Align status\n\n\n  var alignDisabled = true;\n\n  if (align !== null && align !== void 0 && align.points && (status === 'align' || status === 'stable')) {\n    alignDisabled = false;\n  }\n\n  var childNode = children; // Wrapper when multiple children\n\n  if (React.Children.count(children) > 1) {\n    childNode = /*#__PURE__*/React.createElement(\"div\", {\n      className: \"\".concat(prefixCls, \"-content\")\n    }, children);\n  }\n\n  return /*#__PURE__*/React.createElement(CSSMotion, _extends({\n    visible: visible,\n    ref: elementRef,\n    leavedClassName: \"\".concat(prefixCls, \"-hidden\")\n  }, motion, {\n    onAppearPrepare: onShowPrepare,\n    onEnterPrepare: onShowPrepare,\n    removeOnLeave: destroyPopupOnHide,\n    forceRender: forceRender\n  }), function (_ref, motionRef) {\n    var motionClassName = _ref.className,\n        motionStyle = _ref.style;\n    var mergedClassName = classNames(prefixCls, className, alignedClassName, motionClassName);\n    return /*#__PURE__*/React.createElement(Align, {\n      target: getAlignTarget(),\n      key: \"popup\",\n      ref: alignRef,\n      monitorWindowResize: true,\n      disabled: alignDisabled,\n      align: align,\n      onAlign: onInternalAlign\n    }, /*#__PURE__*/React.createElement(\"div\", {\n      ref: motionRef,\n      className: mergedClassName,\n      onMouseEnter: onMouseEnter,\n      onMouseLeave: onMouseLeave,\n      onMouseDownCapture: onMouseDown,\n      onTouchStartCapture: onTouchStart,\n      onClick: onClick,\n      style: _objectSpread(_objectSpread({}, motionStyle), mergedStyle)\n    }, childNode));\n  });\n});\nPopupInner.displayName = 'PopupInner';\nexport default PopupInner;"],"mappings":"AAAA,OAAOA,QAAQ,MAAM,oCAAoC;AACzD,OAAOC,aAAa,MAAM,0CAA0C;AACpE,OAAOC,cAAc,MAAM,0CAA0C;AACrE,OAAO,KAAKC,KAAK,MAAM,OAAO;AAC9B,SAASC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AACxC,OAAOC,KAAK,MAAM,UAAU;AAC5B,OAAOC,eAAe,MAAM,kCAAkC;AAC9D,OAAOC,SAAS,MAAM,WAAW;AACjC,OAAOC,UAAU,MAAM,YAAY;AACnC,OAAOC,gBAAgB,MAAM,oBAAoB;AACjD,SAASC,SAAS,QAAQ,qBAAqB;AAC/C,OAAOC,eAAe,MAAM,mBAAmB;AAC/C,IAAIC,UAAU,GAAG,aAAaV,KAAK,CAACW,UAAU,CAAC,UAAUC,KAAK,EAAEC,GAAG,EAAE;EACnE,IAAIC,OAAO,GAAGF,KAAK,CAACE,OAAO;IACvBC,SAAS,GAAGH,KAAK,CAACG,SAAS;IAC3BC,SAAS,GAAGJ,KAAK,CAACI,SAAS;IAC3BC,KAAK,GAAGL,KAAK,CAACK,KAAK;IACnBC,QAAQ,GAAGN,KAAK,CAACM,QAAQ;IACzBC,MAAM,GAAGP,KAAK,CAACO,MAAM;IACrBC,OAAO,GAAGR,KAAK,CAACQ,OAAO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